export function withDefaults<Props, Defaults extends Partial<Props>>(
  props: Props,
  defaults: Defaults
): Props & Defaults {
  return {
    ...defaults,
    ...props,
  };
}
